/*
 *
 * Copyright (C) 2014 Rigaku Americas Corporation
 *                    9009 New Trails Drive
 *                    The Woodlands, TX, USA  77381
 *
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *    * Redistributions of source code must retain the above copyright
 *      notice(s), this list of conditions and the following disclaimer.
 *    * Redistributions in binary form must reproduce the above copyright
 *      notice(s), this list of conditions and the following disclaimer in the
 *      documentation and/or other materials provided with the distribution.
 *    * Neither the name of the Rigaku Americas Corporation nor the
 *      names of its contributors may be used to endorse or promote products
 *      derived from this software without specific prior written permission.
 *
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED. IN NO EVENT SHALL RIGAKU AMERICAS CORPORATION BE LIABLE
 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
 * SERVICES; LOSS OF USE, DATA OR PROFITS; OR BUSINESS INTERUPTION) HOWEVER
 * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
 * DAMAGE.
 *
 */
//
// README: Portions of this file are merged at file generation
// time. Edits can be made *only* in between specified code blocks, look
// for keywords <Begin user code> and <End user code>.
//
//////////////////////////////////////////////////////////////
//
// Header file for CUIwavelength
//
//    Created by Builder Xcessory Version 5.0.
//    Generated by Code Generator Xcessory 5.0 (05/22/98) .
//
//    This class is a user interface "component", as described
//    in "Object-Oriented Programming with C++ and OSF/Motif",
//    by Douglas Young, Prentice Hall, 1992. ISBN 0-13-630252-1
//
//////////////////////////////////////////////////////////////


// Begin user code block <file_comments>
// End user code block <file_comments>

#ifndef CUIwavelength_H
#define CUIwavelength_H
#include "UIComponent.h"

//
// Globally included information (change thru Output File Names Dialog).
//


//
// Class Specific Includes (change thru the class in Resource Editor).
//



// Begin user code block <head>

#include "CXhelp.h"

// End user code block <head>

class CUIwavelength : public UIComponent

// Begin user code block <superclass>
// End user code block <superclass>
{

// Begin user code block <friends>
// End user code block <friends>

  public:

    CUIwavelength(const char *, Widget);
    CUIwavelength(const char *);
    virtual ~CUIwavelength();
    virtual void create(Widget);
    const char *const  className();
    
    // Begin user code block <public>

    XtPointer m_pObj;
    void (*m_prvOKCallback)(XtPointer, const float, const int, const int);
    void vSetValues(const float, const int, const int);
    void vSetValues(const char *pcString);
    void vGetValues(float *, int *, int *);
    void vParseValues(const char *, double *, int *, int *, char *);
    static int snOptimizeYes;
    static int snOptimizeNo;
    static int snOptionAbs;
    static int snOptionPeak;
    static int snOptionInflRise;
    static int snOptionInflFall;
    static char ms_a4cWavOption[4];
    static char ms_a2cWavOptimize[2];

    // End user code block <public>
  protected:
    // Classes created by this class
    
    // Widgets created by this class
    Widget _CUIwavelength;
    Widget _form;
    Widget _lbOptimize;
    Widget _lbOption;
    Widget _rbOptimize;
    Widget _tbOptimizeNo;
    Widget _tbOptimizeYes;
    Widget _rbOption;
    Widget _tbOptionAbs;
    Widget _tbOptionPeak;
    Widget _tbOptionInflRise;
    Widget _tbOptionInflFall;
    
    // These virtual functions are called from the private callbacks 
    // or event handlers intended to be overridden in derived classes
    // to define actions
    
    virtual void vWavelengthCB(Widget, XtPointer, XtPointer);
    
    // Begin user code block <protected>
    // End user code block <protected>
  private: 
    
    //
    // Default application and class resources.
    //
    static String         _defaultCUIwavelengthResources[];
    static UIAppDefault   _appDefaults[];
    static Boolean        _initAppDefaults;
    //
    // Callback client data.
    //
    UICallbackStruct  *_clientDataStructs;
    
    //
    // Callbacks to interface with Motif.
    //
    static void vWavelengthCBCallback(Widget, XtPointer, XtPointer);
    
    // Begin user code block <private>

      CXhelp *m_poXhelp;

    // End user code block <private>
};

// Begin user code block <tail>
// End user code block <tail>
#endif
